package com.zhongxiangspace.enums;

public enum EmployeesEnum {
    EMPLOYEES_1_5("e1", 1, 5),
    EMPLOYEES_5_10("e2", 5, 10),
    EMPLOYEES_10_20("e3", 10, 20),
    EMPLOYEES_20_30("e4", 20, 30),
    EMPLOYEES_30_50("e5", 30, 50),
    EMPLOYEES_50_10000("e6", 50, 100000);

    private String name;
    private Integer min;
    private Integer max;



    public static EmployeesEnum getEnumObject(String name) {
        for (EmployeesEnum r : EmployeesEnum.values()) {
            if (r.getName().equals(name)) {
                return r;
            }
        }
        return EmployeesEnum.EMPLOYEES_50_10000;
    }


    EmployeesEnum(String name, Integer min, Integer max) {
        this.name = name;
        this.min = min;
        this.max = max;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getMin() {
        return min;
    }

    public void setMin(Integer min) {
        this.min = min;
    }

    public Integer getMax() {
        return max;
    }

    public void setMax(Integer max) {
        this.max = max;
    }
}
